FROM registry.cn-hangzhou.aliyuncs.com/public-image-wk/python-node-base_3.9_16:v1
# 配置时区
ENV TZ=Asia/Shanghai

RUN ln -sf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone

COPY . /app

WORKDIR /app

RUN npm config set registry https://registry.npmmirror.com &&  npm install jsdom@24.0 express body-parser && pip install --user -r requirements.txt && rm -rf /tmp/* && rm -rf /root/.cache/*

EXPOSE 8000

ENTRYPOINT exec python3 server.py